import request from '@/utils/axios'
import {
  URL_API
} from '@/utils/mUtils'
const base = URL_API()


//数据视野列表接口
export function ModulebranchrelationList(params) {
    return request({
      url: `${base}/api/dataView/module_branch_relation/list`,
      method: 'post',
      data: params
    })
  }   

//模块列表接口
export function ModuleList(params) {
    return request({
      url: `${base}/api/module/list`,
      method: 'post',
      data: params
    })
  }    

  //模块创建接口
export function ModulebranchrelationCreate(params) {
    return request({
      url: `${base}/api/dataView/module_branch_relation/create`,
      method: 'post',
      data: params
    })
  } 


//模块删除接口
  export function ModulebranchrelationDelete(params) {
    return request({
      url: `${base}/api/dataView/module_branch_relation/delete`,
      method: 'delete',
      data: params
    })
  }   

  //模块分配权限接口
  export function PermissionAuthorization(params) {
    return request({
      url: `${base}/api/dataView/permission/authorization`,
      method: 'post',
      data: params
    })
  }   

//模块取消权限接口
export function PermissionCancleAuthorization(params) {
    return request({
        url: `${base}/api/dataView/permission/cancle_authorization`,
        method: 'post',
        data: params
    })
}   

//模块取消权限接口
export function PermissionCancleUpdate(params) {
    return request({
        url: `${base}/api/dataView/module_branch_relation/update`,
        method: 'put',
        data: params
    })
}

//员工列表API   
export function AdminBox(params) {
    return request({
        url: `${base}/api/admin/box`,
        method: 'post',
        data: params
    })
}